feat(ui): Wave 0 foundations for AntD → ui-core-components migration - #30560
Conversation
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…sform Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
❌ PR checklist incompleteThis PR cannot be merged until the following are addressed on its linked issue:
The fields live on the linked issue in the Shipping project (open the issue → right sidebar → Projects). After you set them, re-run this check (or push a commit) — issue/project changes do not re-trigger it automatically. Maintainers can bypass this check by adding the |
✅ Playwright Results — workflow succeededValidated commit ✅ 537 passed · ❌ 0 failed · 🟡 0 flaky · ⏭️ 5 skipped · 🧰 0 lifecycle flaky PerformanceBlocking targets: ✅ met · Optimization targets: 🟡 in progress Shard-job maxima below are not the full workflow wall time; the linked run includes build, fixture, planning, and reporting. 🕒 Full workflow signal wall (to summary) 48m 54s ⏱️ Max setup 2m 57s · max shard execution 14m 38s · max shard-job elapsed before upload 17m 49s · reporting 4s 🌐 203.09 requests/attempt · 2.86 app boots/UI scenario · 8.54% common-shard skew Optimization targets still in progress:
How to debug locally# Download playwright-test-results-<shard> artifact and unzip
npx playwright show-trace path/to/trace.zip # view trace |
playwright/e2e/VisualRegression/*.spec.ts is testIgnore'd by the chromium project (it runs under its own playwright-visual.yml workflow), but select_playwright_tests.py still emitted a selector for changed files under that directory. build_playwright_shards.py then rejected the plan because the selector matched no runnable chromium test, crashing "plan-playwright" for any PR touching the visual suite. Add playwright/e2e/VisualRegression/** to impact-map.json's delegatedSpecs, the existing mechanism used for other dedicated-workflow suites (Auth, nightly, Http2, RDF specs), so changed visual-regression specs are routed to delegatedChangedSpecs instead of selectors. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Reformat entityDetails.spec.ts to satisfy Prettier's line-length rule (the UI Checkstyle job runs organize-imports-cli + eslint --fix + prettier --write on changed playwright files and fails the PR if that leaves a diff). Ran the same organize-imports/eslint/prettier chain scoped to the four new visual-regression files; only this file needed a change, and eslint + prettier --check are now clean on all of them. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…mports
parseAntdImports' named-import regex required `{` immediately after
import/type, so `import Button, { Divider } from 'antd';` contributed
nothing to the sweep ledger — silently undercounting any file that
mixes a default and named antd import on one line. Allow an optional
default binding before the braces.
Verified the change is a no-op on the current LEDGER.md: running
ledger.mjs against openmetadata-ui/src/main/resources/ui before and
after the regex change produces byte-identical output (0 files in
this repo currently use the combined default+named import shape).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ting import When every specifier moves out of an antd import AND a target import already exists, move-named-imports.js called `j(path).remove()` on the antd import node, discarding its comments outright. If that import was the file's first statement, its license header vanished from the output. Re-attach any leading comments to the node that becomes the program's new first statement after removal (prepending them ahead of whatever comments that node already carries). Added a regression test with a license header above a first-statement antd import merging into an already-imported target; it fails against the old code (header dropped) and passes with the fix. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
| permissions: | ||
| contents: read |
There was a problem hiding this comment.
Move the Permission Block within the jobs as Best practises :)
Job-scoped permissions per DevOps review convention (matches the e2e workflow's shape). No functional change for this single-job workflow on plain pull_request - the token stays contents:read either way. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
4caff62
|
Code Review
|
| Compact |
|
Was this helpful? React with 👍 / 👎 | Gitar | Powered by Gitar — free for open source



Summary
Foundations for the AntD →
@openmetadata/ui-core-componentsmigration program (Wave 0). No product code changes — tooling, docs, test harness, and CI only.docs/antd-migration/— sweep playbook README + mapping-guide template (the review contract for every future component sweep)tooling/antd-codemods/— jscodeshift scaffold with a genericmove-named-importstransform (6 inline tests: partial move, full-move removal, alias preservation, merge into existing import, no-op, license-header retention)tooling/antd-migration/ledger.mjs— sweep-ledger generator counting antd imports per component per repo plus.ant-*selector occurrences (5 node:test cases; skips vendored/generated dirs; QueryBuilder files excluded as owned by feat(query-builder): migrate QueryBuilderWidgetV1 from antd to core-components #29849)visual-regressionPlaywright project (separate from e2e; chromium project ignores it), determinism helper (fixed clock before navigation, animation freeze, shared screenshot opts), and 16 committed baselines: 13 static pages (incl. collapsed-sidebar variant), table entity details (API-provisioned fixture, name masks), RJSF connector config form, delete-confirmation modal.github/workflows/playwright-visual.yml— PR gate foropenmetadata-ui/**running the visual suite insidemcr.microsoft.com/playwright:v1.57.0-jammy(same image the baselines were generated in, for font-rendering parity), with disk-space reclaim and failure-artifact uploadVerification
tooling/antd-codemods:yarn test6/6 ·tooling/antd-migration:node --test5/5 · eslint/prettier clean on all new spec files ·actionlintclean on the workflow.docs/antd-migration/dead-code-seed.json, 8 files / 451 issues): 3 entries grep-spot-checked, 0 false positives (e.g.DataAssetsHeaderExtraInfohas zero importers). Seed is advisory — deletions must be re-proven in the deleting PR.Notes for reviewers
--update-snapshotspass regenerates baselines.🤖 Generated with Claude Code
Fixes #30564 (Wave 0 of epic #30570)
Greptile Summary
This PR establishes tooling and CI foundations for the AntD migration.
Confidence Score: 3/5
The PR is not yet safe to merge because the codemod can convert selected inline type imports into value imports.
The transform partitions work using only declaration-level importKind, so mixed syntax such as
import { Button, type TabsProps }sendsTabsPropsthrough the value pass and can generate an invalid runtime import; the existing tests cover only standaloneimport typedeclarations.Files Needing Attention: tooling/antd-codemods/transforms/move-named-imports.js, tooling/antd-codemods/tests/move-named-imports.test.js
Important Files Changed
Reviews (7): Last reviewed commit: "Merge origin/main to pick up tw-deprecat..." | Re-trigger Greptile